Library Blazor Components Dialog Reference Classes Dialog Buttons

Buttons

Specifies a combination of buttons to be shown inside a dialog.

[Parameter]
public DialogButton Buttons { get; set; } = DialogButton.Ok | DialogButton.Cancel;

DialogButton enumeration support combining enum items and therefore any combination of buttons can be used.

Examples

In this example only one button (Close) is being shown.

<Dialog Title="Alert" Buttons="DialogButtons.Close">
  This is an alert    
</Dialog>

In this example 2 buttons are shown and pressed button can be handled.

Sign in